Based on a patch Tobias Hunger <tobias.hunger@gmail.com>
AS_IF([ test x$have_libarchive = xyes], [
AC_DEFINE(HAVE_LIBARCHIVE, 1, [Define if we have libarchive.pc])
PKG_CHECK_MODULES(OT_DEP_LIBARCHIVE, $LIBARCHIVE_DEPENDENCY)
+ save_LIBS=$LIBS
+ LIBS=$OT_DEP_LIBARCHIVE_LIBS
+ AC_CHECK_FUNCS(archive_read_support_filter_all)
+ LIBS=$save_LIBS
with_libarchive=yes
], [
with_libarchive=no
gs_free guchar *tmp_csum = NULL;
a = archive_read_new ();
+#ifdef HAVE_ARCHIVE_READ_SUPPORT_FILTER_ALL
+ archive_read_support_filter_all (a);
+#else
archive_read_support_compression_all (a);
+#endif
archive_read_support_format_all (a);
if (archive_read_open_filename (a, gs_file_get_path_cached (archive_f), 8192) != ARCHIVE_OK)
{